import com.hua.pojo.User;
import org.springframework.context.ApplicationContext;
import org.springframework.context.support.ClassPathXmlApplicationContext;

public class Mytest {
    public static void main(String[] args) {
//        User user = new User();
        //spring容器的，就类似婚介所
        ApplicationContext applicationContext = new ClassPathXmlApplicationContext("beans.xml");
        User user1 = (User) applicationContext.getBean("u1");
//        System.out.println(user1);
        user1.show();
    }
}
